package com.example.demo.threadtest;

import com.baomidou.mybatisplus.extension.api.R;

/**
 * *  Author:zlf
 * *  2021/3/9 15:15
 **/
public class RunableZlf implements Runnable {

    private String name;

    public RunableZlf(String name) {
        this.name = name;
    }

    @Override
    public void run() {
        for (int i = 0; i < 100; i++) {
            System.out.println(name);
        }
    }

    public static void main(String[] args) {
        RunableZlf r1 = new RunableZlf("111");
        RunableZlf r2 = new RunableZlf("222");
        new Thread(r1).start();
        new Thread(r2).start();
    }
}
